1. Field of the Invention
The present invention relates to a network failure detection apparatus and a network failure detection method for detecting a failure occurred in a network, and more particularly a network failure detection apparatus and a network failure detection method for detecting a layer-2 loop, a failure occurred in a relay unit constituting the network.
2. Description of the Related Art
A relay unit, which is referred to as layer 2 (L2) switch constituting a network such as LAN, is a kind of network relay unit having a function of transferring packets after determining the destinations from data in the data link layer (the second layer) of the OSI reference model. The data link layer protocol includes MAC (media access control) in Ethernet, etc., and an Ethernet relay unit determining the destination of the data by referring to a MAC address is also referred to as switching hub. Since protocols such as IP, TCP and HTTP are placed in the network layer (the third layer) or higher, the layer-2 switch can transfer packets even when the protocols in the third layer or higher are different.
In a network in which a plurality of terminals are connected through the layer-2 switches, a failure called ‘layer 2 loop’ possibly occurs throughout the entire network area caused by an incorrect cable connection, a fault in the layer-2 switch, etc. The occurrence of the layer 2 loop produces high load conditions in the terminals throughout the entire network area, and brings about a disabled condition of network communication.
FIGS. 1 through 3 show explanation diagrams of the network failure caused by the layer 2 loop (hereafter referred to as ‘L2 loop’). In FIG. 1, the network has the following configuration: In subordination to a ‘layer-2 switch’ (hereafter simply referred to as ‘switch’) SW1, switches SW2, SW3 and SW4 are connected to the network. Further, switches SW5, SW6 and SW7 are connected subordinate to the switches SW2, SW3 and SW4, respectively. Terminals Y1, Y2 and X are then connected to the switches SW5, SW6 and SW7, respectively. In the above network configuration, it is assumed that a loop connection is formed in the switch SW2 due to incorrect cable connection in the switch SW2, resulting in the occurrence of an L2 loop at this point.
Now, an example such that the terminal X transmits a broadcast packet will be explained hereafter. When the broadcast packet is transmitted from the terminal X, the broadcast packet reaches the switch SW2, having the loop occurred therein, via the switches SW7, SW4 and SW1. Each time the broadcast packet is circulated in the loop occurred in the switch SW2, the broadcast packet is transmitted throughout the entire area of the network (subnet). Because such the loop circulation is performed at a wire speed, the result is that the broadcast packet continues to be transmitted throughout the entire network from the switch SW2 at wire speed (which is referred to as ‘broadcast storm’), and the terminals in the network fall into heavy load conditions.
Also, when the broadcast packet is input to one of the plurality of ports in each switch, the switch stores the MAC address of the originating terminal included in the broadcast packet. The switch then recognizes the direction, in which the originating terminal of the broadcast packet is existent, to be the direction of the input port in regard to the originating terminal of interest (hereafter, the above recognition may also be represented as ‘learning the address’). Accordingly, as a result of the above broadcast storm, there emerges a switch in which ‘incorrect learning’ (hereafter referred to as ‘mislearning’) of the originating terminal address is made. Namely, because each switch recognizes the source address of the broadcast packet to be located in the direction of the point of the L2 loop occurrence (i.e. the switch SW2) the address mislearning of the originating terminal is brought about in the respective switches which are located on the path between the terminal X and the point of the L2 loop occurrence. More specifically, the address of the terminal X is learned as if the terminal X transmitting the broadcast packet exists in the switch SW2 in which the L2 loop is occurred, as a virtual image of the terminal X. Therefore, in the figure, the switches SW7, SW4, SW1 and SW2, which are located on the path between the terminal X and the point of the L2 loop occurrence, mislearn the address of the terminal X. As such, in a state of the L2 loop being occurred, when a broadcast packet is transmitted from a terminal, switches located on a path between the terminal concerned and the point of the occurrence of the L2 loop mislearn the terminal address concerned.
In regard to the switches SW3, SW5 and SW6, no such mislearning occurs, which is merely because a packet reception direction in case of a packet transmitted from the actual terminal X happens to coincide with a packet reception direction in case of a packet transmitted from the point of the L2 loop occurrence.
As described above, in the state of mislearning the address of the terminal X, the terminal Y1 transmits a unicast packet to the terminal X, as shown in FIG. 2. The unicast packet reaches the switch SW2 via the switch SW5. Since the switch SW2 has mislearned the address of the terminal X, the unicast packet continues to circulate in the L2 loop occurred in the switch SW2. As a result, the unicast packet does not reach the terminal X, and the communication between the terminal Y1 and the terminal X becomes not possible. Also, the switch SW2 mislearns the address of the terminal Y1 as if the terminal Y1 is existent in the L2 loop. As such, when a unicast packet is transmitted to an address which has been mislearned so as to reach a point of occurrence of the L2 loop, in the switch SW2 having the L2 loop occurred therein, the address of the originating terminal of the unicast packet is mislearned to be located in the direction of the L2 loop. Here, another switch SW5 correctly learns the address of the terminal Y1.
Similarly, as shown in FIG. 3, in the state that the address of the terminal X is mislearned as described above, the terminal Y2 transmits a unicast packet to the terminal X. The unicast packet reaches the switch SW2 via the switches SW6, SW3 and SW1. The switch SW2 has mislearned the address of the terminal X, and the unicast packet continues to circulate in the L2 loop occurred in the switch SW2. As a result, the unicast packet does not reach the terminal X, and the communication with the terminal X becomes not possible. Also, the switch SW2 mislearns the address of the terminal Y2, as if the terminal Y2 is existent in the L2 loop. Here, other switches SW6, SW3 and SW1 correctly learn the address of the terminal Y2.
As a technique for detecting such the L2 loop which causes a network failure, for example, in the official gazette of the Japanese Unexamined Patent Publication No. 2001-197114, an L2 loop detection method, in which an infinite loop is determined by analyzing a receiving frame, is disclosed.
When the L2 loop occurs, conventionally, localization of the occurred L2 loop point has been made by manually ejecting and inserting cables of the layer-2 switch, or by repeating an information acquisition procedure related to the connection condition of the switch being suspected of the failure. Accordingly, a substantially long time (a few hours to a few days) and a large amount of work have been required before finding out the L2 loop point.
Further, according to the technique disclosed in the above official gazette of the Japanese Unexamined Patent Publication No. 2001-197114, it is possible to detect the occurrence of the L2 loop somewhere in the network (subnetwork or subnet). However, it is not possible to identify an exact point of the L2 loop in the subnet.